package com.greystripe.sdk;

import android.content.Context;
import android.hardware.Sensor;
import android.hardware.SensorManager;
import android.webkit.JavascriptInterface;

final class a
{
  private SensorManager a;
  private Sensor b;
  private b c;
  private aa d;
  private boolean e;

  public a(Context paramContext, aa paramaa)
  {
    this.d = paramaa;
    this.c = new b(this, (byte)0);
    this.e = false;
    this.a = ((SensorManager)paramContext.getSystemService("sensor"));
  }

  @JavascriptInterface
  public final void start()
  {
    try
    {
      aa localaa = this.d;
      if (localaa == null);
      while (true)
      {
        return;
        if (!this.e)
        {
          this.b = this.a.getDefaultSensor(1);
          this.a.registerListener(this.c, this.b, 1);
          this.e = true;
        }
      }
    }
    finally
    {
    }
  }

  @JavascriptInterface
  public final void stop()
  {
    if (this.a != null)
    {
      this.a.unregisterListener(this.c);
      this.e = false;
    }
  }
}

/* Location:           E:\android\Toy Defense 2_dex2jar.jar
 * Qualified Name:     com.greystripe.sdk.a
 * JD-Core Version:    0.6.2
 */